package com.excesys.exsecs.eco.mapper;

import com.excesys.exsecs.common.data.datascope.ExsecsBaseMapper;
import com.excesys.exsecs.eco.entity.EcoPowerHourFlow;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDateTime;
import java.util.Map;

import java.util.List;
import java.util.Map;

@Mapper
public interface EcoPowerHourFlowMapper extends ExsecsBaseMapper<EcoPowerHourFlow> {

	double getSumTotalPower(@Param("date")String date);

    Map<String, Double> sumIncrByTimeValue(@Param("timeValue") LocalDateTime timeValue);

	List<Map<String, Object>> chartPower(@Param("startTime") String startTime, @Param("endTime") String endTime);


	List<Map> qurryEnergy(@Param("params") Map params);

	List<Map> selectDevNames();

	List<String> dateRange(@Param("dateFormat") String dateFormat,
						   @Param("startTime") String startTime,
						   @Param("endTime") String endTime);

	List<Map<String, Object>> electricalEnergyListByMonth(@Param("startDate") String startDate,@Param("endDate") String endDate, @Param("idList") List<String> idList);

	List<Map<String, Object>> electricalEnergyListByDay(@Param("startDate") String startDate,@Param("endDate") String endDate, @Param("idList") List<String> idList);

	List<Map<String, Object>> electricalEnergyListByYear(@Param("startDate") String startDate,@Param("endDate") String endDate, @Param("idList") List<String> idList);

}